# $Id$
# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Jan de Groot <jgc@archlinux.org>

pkgname=totem-plparser
pkgver=3.26.0
pkgrel=1
pkgdesc="Simple GObject-based library to parse and save a host of playlist formats"
url="https://git.gnome.org/browse/totem-pl-parser"
license=(LGPL)
arch=(i686 x86_64)
depends=(gmime3 libarchive libquvi libxml2)
makedepends=(gobject-introspection git gtk-doc libsoup meson)
_commit=279ca9c68f9ed24a29bec5ababcdbf97fd5d08e7  # tags/V_3_26_0^0
source=("git+https://git.gnome.org/browse/totem-pl-parser#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd totem-pl-parser
  git describe --tags | sed 's/^V_//;s/_/./g;s/-/+/g'
}

prepare() {
  mkdir build
  cd totem-pl-parser
}

build() {
  cd build
  meson setup --prefix=/usr --libexecdir=/usr/lib --buildtype=release -Denable-gtk-doc=true ../totem-pl-parser
  ninja
}

package() {
  cd build
  DESTDIR="$pkgdir" ninja install
}
